package com.danco.training.zaneuskaya.faces;

import java.io.Serializable;

import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

/**
 * @author Zaneuskaya Aliaksandra
 *
 */
@Component
@Scope("request")
public class NavigationBean implements Serializable {

	private static final String USER_MAIN_FACES_REDIRECT_TRUE = "/user/main?faces-redirect=true";
	private static final String MESSAGES_MESSAGES = "/messages/messages";
	private static final String USERS_PAGE = "/user/list";
	private static final String FORUMS_PAGE = "/forum/list";
	private static final String EVENTS_PAGE = "/event/list";
	private static final String HOME_PAGE = "/home?faces-redirect=true";
	private static final String REGISTRATION_PAGE = "/registration?faces-redirect=true";
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public String toRegistration() {
		return REGISTRATION_PAGE;
	}

	public String toLogin() {
		return HOME_PAGE;
	}

	public String toEvents() {
		return EVENTS_PAGE;
	}

	public String toForums() {
		return FORUMS_PAGE;
	}

	public String toUsers() {
		return USERS_PAGE;
	}

	public String toMessages() {
		return MESSAGES_MESSAGES;
	}

	public String toCurrentUserPage() {
		return USER_MAIN_FACES_REDIRECT_TRUE;
	}

}
